# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=mp3splt-gtk
pkgver=0.9.2
pkgrel=4
pkgdesc="Gtk frontend for mp3splt"
url="https://mp3splt.sourceforge.net/"
arch="all"
license="GPL-2.0-or-later"
makedepends="gtk+3.0-dev gst-plugins-base-dev libmp3splt-dev
	autoconf automake libtool"
subpackages="$pkgname-doc $pkgname-lang"
source="https://prdownloads.sourceforge.net/mp3splt/mp3splt-gtk-$pkgver.tar.gz
	gcc-10.patch
	werrorformat.patch
	"

prepare() {
	default_prepare
	update_config_sub
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--disable-gnome \
		--disable-audacious
	sed -i -e 's/-DGTK_DISABLE_DEPRECATED//' Makefile src/Makefile
	make
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
e837cbc0759cd6535fc466099a170d066ab72b4854f8546f524261fe660887f5d2add60d9fa1e19d68d811004c682a324b5bcba86aa8cb89ae1ad2bc2f9b1d9d  mp3splt-gtk-0.9.2.tar.gz
108d0c5ce4d2682c8b281a749b6376aeac00f9e56ed2cc61d132ea9d7ecbd90ce24447fdc2634bd47a099c79d62b650d20d7f4dfbc42b18cf5e744601982c7be  gcc-10.patch
348b987745ee31cde432c24e0283f950054824413fd98a992d67022037bd23be125995187936d383e314e8f78c1a2210e326576411be5f44f7c90c6a795526d6  werrorformat.patch
"
